package com.zukxu.items.project.comment.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.zukxu.items.project.comment.entity.VideoComment;
import com.zukxu.items.project.comment.dto.VideoCommentDTO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author wangziqi
 * @since 2020-09-15
 */
@Mapper
public interface VideoCommentMapper extends BaseMapper<VideoComment> {
	/**
	 * 通过id进行查询返回DTO对象
	 * @param videoId
	 * @param parentId
	 * @param current
	 * @param size
	 * @return
	 */
	List<VideoCommentDTO> selectCommentById(
			@Param("videoId") String videoId,
			@Param("parentId") String parentId,
			@Param("current")Integer current,
			@Param("size")Integer size
	);
}
